package priv.yiyuan.example.design;

import java.io.IOException;

/**
 * 基础装饰器类
 *
 * @author YiYuan
 * @data 2025/8/8
 * @apoNote
 */
public abstract class DataReaderDecorator implements DataReader {

    protected final DataReader wrappedReader;

    public DataReaderDecorator(DataReader wrappedReader) {
        this.wrappedReader = wrappedReader;
    }

    @Override
    public String read() throws IOException {
        return wrappedReader.read();
    }

    @Override
    public String getSourceInfo() {
        return wrappedReader.getSourceInfo();
    }
}
